package Graphics;

import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.awt.event.MouseEvent;
import java.awt.event.MouseListener;

public class GameMouseListener implements MouseListener {
	private ActionListener listener;
	
	public GameMouseListener(ActionListener listener) {
		super();
		this.listener = listener;
	}
	
	public void mouseClicked(MouseEvent event) { }
	public void mouseEntered(MouseEvent event) {  }
	public void mouseExited(MouseEvent event) {	}
	public void mousePressed(MouseEvent event) {
		// new ActionEvent(Object, int, String)
		ActionEvent jumpEvent = new ActionEvent(new Object(), 0, "jump");
		
		listener.actionPerformed(jumpEvent);
	}
	public void mouseReleased(MouseEvent event) { }
}
